package interface_01;

public class Main {

    public static void main(String[] args) {
	// write your code here
        Pet p1 = new Pet("绿毛",300,"乌龟");
        p1.print();

        Cat c1 = new Cat("加菲",30);
        c1.print();

        Turtle t1 = new Turtle("拉斐尔",25);
        t1.print();

        Animal[] animals = new Animal[2];

        animals[0] = c1;
        animals[1] = t1;

        for (Animal a:animals) {
            a.eat();
            a.travel();
        }
    }
}
